#ifndef __RINGBUFFERBASE_H_
#define __RINGBUFFERBASE_H_


#include <iostream>
#include <unistd.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include "Ringbufferbase.h"

class CRingbufferBase
{
   typedef struct Ringbuffer_t
   {
      char *data;
      int datalen;
      int in_flg; 
      int out_flg;
   }Ringbuffer;
   public :
     CRingbufferBase(int maxbuff_len);
     ~CRingbufferBase();
     int RingbuffRead(char *readdata, int readlen);
     int RingbuffWrite(char *writedata, int writelen);
     int RingbuffIsempty();
     int RingbuffIsFull();
     int RingbuffRemainCount();
   private:
     Ringbuffer m_ringbuf;

};



#endif